package com.wry.wry_test.controller;

import com.wry.wry_test.model.HotelDoc;
import com.wry.wry_test.service.HotelService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Author: wangrongyi
 * @Date: 2024/8/6 13:58
 * @Description:
 */
@RestController
@Slf4j
@RequestMapping("/hotel")
public class HotelController {

    @Autowired
    private HotelService hotelService;

    @GetMapping("/getAllHotelToES")
    public void getAllHotelToES() {
        hotelService.getAllHotelToES();
    }

    @GetMapping("/queryDoc")
    public List<HotelDoc> queryDoc() {
        return hotelService.queryDoc();
    }
}
